package com.ytjj.qmyx.admin.service;

import com.ytjj.common.api.CommonPage;
import com.ytjj.common.api.CommonResult;
import com.ytjj.qmyx.admin.model.OrdersForbid;
import com.ytjj.qmyx.admin.model.request.*;
import com.ytjj.qmyx.admin.model.request.channel.ChannelReturnGoodsRequest;
import com.ytjj.qmyx.admin.model.response.*;
import com.ytjj.qmyx.mall.model.BankerStoreAddressResponse;
import com.ytjj.qmyx.mall.model.Orders;
import com.ytjj.qmyx.mall.model.OrdersPay;
import com.ytjj.qmyx.mall.model.OrdersRefund;

import java.util.List;

/**
 *
 *
 * @Version: 1.0
 */
public interface ReturnGoodsService {

	CommonPage<ReturnGoodsResponse> selectList(ReturnGoodsRequest request);

	CommonPage<ReturnGoodsResponse> selectReturnList(ReturnGoodsRequest request);

	/**
	 * 退款数据，不分页
	 */
//	CommonPage<ReturnGoodsResponse> getReturnData(ChannelReturnGoodsRequest request);

	CommonResult<ReturnGoodsDetail> getReturnGoodsDetailInfo(Integer id);

	CommonResult<ReturnGoodsDetail> getReturnGoodsDetailInfoBySupplyChain(Integer id);

	CommonResult auditSuccess(Integer id);

	/**
	 * 批量审核
	 */
	CommonResult batchAuditSuccess(List<Integer> ids);

	Integer auditFail(Integer id, String serviceRemarks,String rejectType);

	void synvReturnInfo(ReturnGoodsSyncRequest request);

	Integer refundGoods(Integer id, String refundDesc);

	void syncReturnRegister(String isRpc);

	/**
	 * 根据供应商id获取供应商退货地址
	 * @param bankerId
	 * @return
	 */
	List<BankerAddressResponse> getReturnAddressByBankerId(Integer bankerId);

	List<BankerStoreAddressResponse> newGetReturnAddressByBankerId(Integer bankerId);

	List<BankerStoreAddressResponse> newGetReturnAddressByBankerId(String bankerIds);

	List<BankerAddressResponse> getReturnAddressByAddressId(Integer addressId);

	void batchSyncReturnRegister(List<Integer> returnGoodsIds);

	void syncReturnRegisterById(Integer returnGoodsId);

	CommonResult deleteReturnGoods(Integer id);

	CommonResult creatReturnGoods(ReturnGoodsReq returnGoodsRequest);

//	Integer check(Integer id);

//	boolean auditSuccessAndRefund(Integer id);

//	Integer affirmSuccessOrRefund(Integer id, Integer num);

	void insertAddress(BankerAddressRequest request);

    Integer updateStatus(Integer id);

	CommonResult getProvince(Integer id);

	CommonResult getCity(Integer id);

	CommonResult getArea(Integer id);

	CommonResult removeReturnGoods(Integer id);

	List<OrderQueryResponse> querySupplyChainOrderInfo(List<String> childOrderNo);

	Integer handleRefundV3(Orders orders, OrdersRefund ordersRefund, OrdersPay ordersPay, Integer id, String refundDesc);

	/**
	 * 锁单
	 */
	CommonResult lockOrder(OrdersForbidRequest ordersForbidRequest);

	/**
	 * 获取锁单信息
	 */
	OrdersForbidResponse getLockOrderInfo(Integer id);


	/**
	 * 分页获取锁单信息
	 */
	CommonPage<OrdersForbidResponse> getLockOrderInfoByPage(OrdersForbidPageRequest request);


	boolean checkUserPhoneIsLimitRole();
}
